import request from "../utils/request.ts";

export function findPages(pageNum:number, pageSize:number) {
    return request({
        url: "/contract/findPages",
        method: "get",
        params: {
            pageNum: pageNum,
            pageSize: pageSize
        }
    });
}

export function findPagesByKey(data:any) {
    return request({
        url: "/contract/findPagesByKey",
        method: "post",
        data
    });
}

export function insert(data:any) {
    return request({
        url: "/contract/insert",
        method: "post",
        data
    });
}

export function deleteOne(contractid:string) {
    return request({
        url: "/contract/delete",
        method: "post",
        params: {
            contractid: contractid
        }
    });
}

export function findDetail(contractid:string) {
    return request({
        url: "/contract/findDetail",
        method: "get",
        params: {
            contractid: contractid
        }
    });
}
